package cn.tedu.hospitalqd.mapper;

import cn.tedu.hospitalqd.pojo.entity.Pharmacy;
import cn.tedu.hospitalqd.pojo.vo.PharmacyListItemVO;
import cn.tedu.hospitalqd.pojo.vo.PharmacyStandardVO;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;

import java.util.List;

@Repository
public interface PharmacyMapper {

    int insert(Pharmacy pharmacy);

    int insertBatch(List<Pharmacy> pharmacyList);

    int deleteById(Long id);

    int deleteByIds(Long[] idList);

    int update(Pharmacy pharmacy);

    int count();

    int countByName(String name);

    int countByNameAndNotId(@Param("id") Long id, @Param("name") String name);

    PharmacyStandardVO getStandardById(Long id);

    List<PharmacyListItemVO> list();


}
